Flex Custom MenuBar

131 views
Skip to first unread message

Geet.Kartikeya

unread,
Jul 20, 2008, 7:51:47 PM7/20/08
to Flex India Community
Greetings of the Day -


I'm trying to make a custom menubar with an image, like this one:

http://s350.photobucket.com/albums/q416/geetk/?action=view&current=buzzimage.jpg

can anyone describe how I would do it?

I just don't know how to use the image as an item on a menubar


Thanks,
Geet Kartikeya

Geet.Kartikeya

unread,
Jul 21, 2008, 5:25:23 PM7/21/08
to Flex India Community

Bump, anyone?


On Jul 20, 6:51 pm, "Geet.Kartikeya" <geet.kartik...@gmail.com> wrote:
> Greetings of the Day -
>
> I'm trying to make a custom menubar with an image, like this one:
>
> http://s350.photobucket.com/albums/q416/geetk/?action=view¤t=bu...

Vijay

unread,
Jul 21, 2008, 11:43:02 PM7/21/08
to Flex India Community
Hello Geet,

This is how you do it.
I guess the code is self explanatory.

Actionscript :

[Bindable]
[Embed("assets/images/disk.png")]
public var saveIcon:Class;

[Bindable]
[Embed("assets/images/printer.png")]
public var printIcon:Class;


mxml :

<mx:XML id="menuBarCollection" format="e4x">
<root>
<menuitem label="Save" icon="saveIcon"></menuitem>
<menuitem label="Print" icon="printIcon"></menuitem>
</root>
</mx:XML>

<mx:MenuBar id="XYZ"
itemClick="CallCorrespondingToolbar(event)"
labelField="@label"
iconField="@icon"
dataProvider="{menuBarCollection}"
showRoot="false" />

prashanth samanth

unread,
Jul 22, 2008, 12:23:24 AM7/22/08
to flex_...@googlegroups.com
Try using PopUpButton for the Images
--
Prashanth Samanth

Geet.Kartikeya

unread,
Jul 22, 2008, 12:24:55 PM7/22/08
to Flex India Community
Thank you everyone for helping me.


-Geet Kartikeya

On Jul 21, 11:23 pm, "prashanth samanth" <psaman...@gmail.com> wrote:
> Try using PopUpButton for the Images
>
> On Tue, Jul 22, 2008 at 2:55 AM, Geet.Kartikeya <geet.kartik...@gmail.com>
> wrote:
>
>
>
>
>
>
>
> > Bump, anyone?
>
> > On Jul 20, 6:51 pm, "Geet.Kartikeya" <geet.kartik...@gmail.com> wrote:
> > > Greetings of the Day -
>
> > > I'm trying to make a custom menubar with an image, like this one:
>
> > >http://s350.photobucket.com/albums/q416/geetk/?action=view¤t=bu...
>
> > > can anyone describe how I would do it?
>
> > > I just don't know how to use the image as an item on a menubar
>
> > > Thanks,
> > > Geet Kartikeya
>
> --
> Prashanth Samanth- Hide quoted text -
>
> - Show quoted text -
Reply all
Reply to author
Forward
0 new messages